import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomeView.vue'
import ManagementLayout from '../components/layout'

Vue.use(VueRouter)

const routes = [
  {
    name: 'ManagementLayout',
    path: '/',
    component: ManagementLayout,
    redirect: '/exchangeMatrix',
    children: [
      {
        path: '/deviceTopology',
        name: 'DeviceTopology',
        component: () => import('@/views/DeviceTopology.vue')
      },
      {
        path: '/exchangeMatrix',
        name: 'home',
        component: HomeView
      },
      {
        path: '/broadbandSignal',
        name: 'BroadbandSignal',
        component: () => import('@/views/BroadbandSignal.vue')
      },
      {
        path: '/portableAntenna',
        name: 'PortableAntenna',
        component: () => import('@/views/PortableAntenna.vue')
      },
      {
        path: '/highSpeedDemodulator',
        name: 'HighSpeedDemodulator',
        component: () => import('@/views/HighSpeedDemodulator.vue')
      },
      {
        path: '/deviceNnetworkConfiguration',
        name: 'DeviceNnetworkConfiguration',
        component: () => import('@/views/DeviceNnetworkConfiguration.vue')
      },
      {
        path: '/remoteDesktop',
        name: 'RemoteDesktop',
        component: () => import('@/views/RemoteDesktop.vue')
      }
    ]
  }
  //   {
  //     path: '/about',
  //     name: 'about',
  //     // route level code-splitting
  //     // this generates a separate chunk (about.[hash].js) for this route
  //     // which is lazy-loaded when the route is visited.
  //     component: () => import(/* webpackChunkName: "about" */ '../views/AboutView.vue')
  //   }
]

const router = new VueRouter({
  routes
})

export default router
